Skip to main content

DigiLocker Pull Parameters API

The following document highlights the details of the DigiLocker Pull Parameters API.

API Description

Objective

The DigiLocker Pull Parameters API retrieves the required parameters for fetching documents from DigiLocker.
These parameters serve as inputs for the DigiLocker - Fetch Document API.

InputOutput
An array of document codes (combining organization IDs and document types) for which to pull parameters. These codes are retrieved from the DigiLocker - Fetch Document Type Map APIThe parameters required to fetch documents from DigiLocker

API URL

https://ind-verify.hyperverge.co/api/digilocker/pullParameters

API Endpoint

pullParameters

Overview

The DigiLocker Pull Parameters API is RESTful and uses standard HTTP verbs and status codes. The responses are in JSON format and you should upload all images and files as form-data through a POST request.

Method - POST

Authentication

You need a unique pair of application ID ( appId ) and application key ( appKey ) from HyperVerge to verify your identity for accessing the API.

Headers

HeaderMandatory / OptionalDescriptionInput Format
content-type MandatoryThis parameter defines the media type for the request payloadapplication/json
appId MandatoryThe application identifier shared by HyperVerge. You can find the details in the dashboard's credentials tabThis should be a unique value
appKey MandatoryThe application key shared by HyperVerge. You can find the details in the dashboard's credentials tabThis should be a unique value
transactionIdOptionalA unique identifier for tracking a user journeyThis should be both unique and easily associated with the user's journey in your application(s)

Inputs

The following table provides the details of the parameters required for the DigiLocker Pull Parameters API 's request body:

ParameterMandatory / OptionalTypeDescriptionInput FormatDefault Value
documentCodesMandatoryarrayAn array of document codes, each combining an organization ID and document type, retrieved from the DigiLocker Fetch Supported Documents and Issuers API response orgID_docType. For example, "002204_DRVLC", "001891_PANCR" Not Applicable

Request

The following code snippet demonstrates a standard curl request for the DigiLocker Pull Parameters API:

curl --location --request POST 'https://ind-verify.hyperverge.co/api/digilocker/pullParameters' \
--header 'Content-Type: application/json' \
--header 'appId: <Enter_the_HyperVerge_appId>' \
--header 'appKey: <Enter_the_HyperVerge_appKey>' \
--header 'transactionId: <Enter_the_transactionId>' \
--data-raw '["002204_DRVLC", "001891_PANCR"]'

Success Response

The following code snippet demonstrates a success response from the DigiLocker Pull Parameters API:

{
"status": "success",
"statusCode": "200",
"result": [
{
"docId": "001891_PANCR",
"params": [
[
{
"label": "PAN No.",
"paramname": "panno",
"example": "ABCD123EF"
},
{
"label": "Name as in PAN Card",
"paramname": "PANFullName",
"example": "RAMESHWAR KUMAR SINGH"
}
]
]
},
{
"docId": "002204_DRVLC",
"params": [
[
{
"label": "DL No",
"paramname": "dlno",
"example": "Ex. JH02/2009/236543"
}
]
]
}
]
}

Success Response Details

The following table outlines the details of the success response from the DigiLocker Pull Parameters API:

ParameterTypeDescription
statusstringThe status of the request
statusCodestringThe HTTP status code for the response
resultarrayAn array of objects, each containing document parameters
result[].docIdstringThe document ID for which parameters are returned
result[].paramsarrayAn array containing parameter groups. Each group is an array of parameter objects
result[].params[][].labelstringThe display label for the parameter
result[].params[][].paramnamestringThe parameter name to be used when fetching the document
result[].params[][].examplestringAn example value for the parameter

Error Responses

The following are some error responses from the DigiLocker Pull Parameters API:

{
"status": "success",
"statusCode": "200",
"result": [
{
"docId": "001891A_PANCR", // the entered docId
"error": {
"error": "invalid_parameter",
"message": "orgid parameter is missing or invalid"
}
}
]
}

Error Response Details

A failure or error response contains an error object within the result array for the specific document ID that failed.
The following table lists all error responses:

Status CodeError MessageError DescriptionError Resolution
200invalid_parameterThe document code (ordID / docType) provided is either missing or invalid Verify that the document codes match valid document IDs from the DigiLocker - Fetch Document Type Map API
401Missing/Invalid credentialsThe request is either missing the mandatory appId and appKey combination or has invalid valuesProvide valid appId and appKey credentials in the request
500Internal Server ErrorThere was an error with HyperVerge's serverPlease check the request headers or contact the HyperVerge team for resolution
Was this helpful?
Ask AIBeta
Hi! How can I help?
Ask me anything about HyperVerge products, APIs, and SDKs.
Try asking: